package com.ptit.giaothong.xebus;

import android.app.Activity;
import android.widget.TextView;

import com.ptit.giaothong.MainActivity;
import com.ptit.giaothong.R;

public class Busdetailt {
	private Activity activity;
	private TextView txtname, txttansuat, txttimehd, txtgiave, txtquangduong,
			txttimechuyen, txtluotdi, txtluotve;

	public Busdetailt(Activity activity) {
		this.activity = activity;
	}

	public void Init(Itembus item) {
		MainActivity.keypage = 1;

		activity.setContentView(R.layout.busdetailt);

		txtname = (TextView) activity.findViewById(R.id.txttuenso);
		txtname.setText(item.getName().toUpperCase());

		txttansuat = (TextView) activity.findViewById(R.id.totalpoint_id);
		txttansuat.setText(item.getTansuat());

		txttimehd = (TextView) activity.findViewById(R.id.txttimehd);
		txttimehd.setText(item.getTime());

		txtgiave = (TextView) activity.findViewById(R.id.txtgiave);
		txtgiave.setText(item.getPrice());

		txtquangduong = (TextView) activity.findViewById(R.id.txtquangduong);
		txtquangduong.setText(item.getQuangduong());

		txttimechuyen = (TextView) activity.findViewById(R.id.txttimemoichuyen);
		txttimechuyen.setText(item.getTotaltime());

		txtluotdi = (TextView) activity.findViewById(R.id.txtluotdi);
		txtluotdi.setText(item.getLuotdi());

		txtluotve = (TextView) activity.findViewById(R.id.txtluotve);
		txtluotve.setText(item.getLuotve());
	}
}
